﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

/// <summary>
/// Summary description for YKienKhachHangEntity
/// </summary>
public class YKienKhachHangEntity
{

    private int idYK;
    private string tieuDe;
    private string tenKH;
    private string dienThoai;
    private string diaChi;
    private DateTime ngayGui;
    private string noiDung;
    private string email;
    public YKienKhachHangEntity()
    { }
    public YKienKhachHangEntity(int idYK, string tieuDe, string tenKH, string dienThoai, string diaChi, DateTime ngayGui, string noiDung, string email)
    {
        this.idYK = idYK;
        this.tieuDe = tieuDe;
        this.tenKH = tenKH;
        this.dienThoai = dienThoai;
        this.diaChi = diaChi;
        this.ngayGui = ngayGui;
        this.noiDung = noiDung;
        this.email = email;
    }
    public int IdYK
    {
        get { return this.idYK; }
        set
        {
            if (value == null)
                throw new Exception("idYK not allow nullvalue.");
            this.idYK = value;
        }
    }
    public string TieuDe
    {
        get { return this.tieuDe; }
        set
        {
            if (value == null)
                throw new Exception("tieuDe not allow nullvalue.");
            this.tieuDe = value;
        }
    }
    public string TenKH
    {
        get { return this.tenKH; }
        set
        {
            if (value == null)
                throw new Exception("tenKH not allow nullvalue.");
            this.tenKH = value;
        }
    }
    public string DienThoai
    {
        get { return this.dienThoai; }
        set { this.dienThoai = value; }
    }
    public string DiaChi
    {
        get { return this.diaChi; }
        set { this.diaChi = value; }
    }
    public DateTime NgayGui
    {
        get { return this.ngayGui; }
        set { this.ngayGui = value; }
    }
    public string NoiDung
    {
        get { return this.noiDung; }
        set { this.noiDung = value; }
    }
    public string Email
    {
        get { return this.email; }
        set { this.email = value; }
    }
    public override string ToString()
    {
        return this.idYK + "; " + this.tieuDe + "; " + this.tenKH + "; " + this.dienThoai + "; " + this.diaChi + "; " + this.ngayGui + "; " + this.noiDung + "; " + this.email + "; ";
    }
    public override bool Equals(Object obj)
    {
        YKienKhachHangEntity me = (YKienKhachHangEntity)obj;
        bool ret = this.IdYK.Equals(me.IdYK);
        return ret;
    }
    public override int GetHashCode()
    {
        return this.IdYK.GetHashCode();
    }
}